import service from './request'

const cqBaseUrl = import.meta.env.VITE_CQ_SERVER_URL
const headers = { 'Content-Type': 'application/json' }

// 查询任务分析区指标接口
export const getOrgBiologicalAssetsInfo = (params) => {
  return service.post(
    cqBaseUrl +
      '/kapi/v2/wens/wens_pig_asset_manager/FirmBiologicalAssetsController/getOrgBiologicalAssetsInfo',
    {
      ...params
    },
    {
      headers: headers
    }
  )
}

// 进苗异常事件
export const getCollarSeedlingAbnormalInfo = (params) => {
  return service.post(
    cqBaseUrl +
      '/kapi/v2/wens/wens_pig_asset_manager/FirmBiologicalAssetsController/getCollarSeedlingAbnormalInfo',
    {
      ...params
    },
    {
      headers: headers
    }
  )
}

// 未处理尾猪事件
export const getUntreatedTailPigInfo = (params) => {
  return service.post(
    cqBaseUrl +
      '/kapi/v2/wens/wens_pig_asset_manager/FirmBiologicalAssetsController/getUntreatedTailPigInfo',
    {
      ...params
    },
    {
      headers: headers
    }
  )
}

// 户均尾猪处理天数
export const getPerHouseholdInfo = (params) => {
  return service.post(
    cqBaseUrl +
      '/kapi/v2/wens/wens_pig_asset_manager/FirmBiologicalAssetsController/getPerHouseholdInfo',
    {
      ...params
    },
    {
      headers: headers
    }
  )
}